import request from '@/utils/request'

// 新增
export function save(data) {
  return request({
    url: '/receivables/save',
    method: 'post',
    data
  })
}
// 应收(付)金额修改
export function updateMoney(data) {
  return request({
    url: '/receivables/updateMoney',
    method: 'post',
    data
  })
}
// 删除
export function del(data) {
  return request({
    url: '/receivables/delete',
    method: 'post',
    data
  })
}
// 获取应收列表
export function findReceivablesList(companyId) {
  return request({
    url: '/receivables/findReceivablesList',
    method: 'get',
    params: { companyId }
  })
}
// 获取应付列表
export function findPaymentList(companyId) {
  return request({
    url: '/receivables/findPaymentList',
    method: 'get',
    params: { companyId }
  })
}
// 根据id获取实体类
export function findById(receivablesId) {
  return request({
    url: '/receivables/findOne',
    method: 'get',
    params: { receivablesId }
  })
}
